# -*- coding: utf-8 -*-
<%inherit file="../autohandler"/>
%if c.pages is not None:
    <%include file="toolPanel.myt"/>
%endif
<script language="javascript" src="/lib.js" type="text/javascript"></script>

<table width="90%" border="0" align="center" cellpadding="0" cellspacing="1">
  <tr><td><div id="add" /></td></tr>
</table>
<table id="tbContent" width="90%" border="0" align="center" cellpadding="0" cellspacing="1" class="BoxCenter">
  <tr class="headlineTextCenter"><td height="20" bgcolor="#C5CED9" width="5%">№</td>
    <td height="20" bgcolor="#C5CED9" width="50%">Наименование</td>
    <td height="20" bgcolor="#C5CED9" width="22%">Автор</td>
    <td height="20" bgcolor="#C5CED9" width="8%">Год выпуска</td>
    <td height="20" bgcolor="#C5CED9" colspan="3" width="2%">Действия</td>
  </tr>
  <tr id="trNew"><td colspan="8">
      <div id="divNewItem"></div>
      <div id="divNewShowEdit"></div></td>
  </tr>
  <tr bgcolor="#F0F0F0"></tr>

%for post in c.biblioPosts:
  <tr bgcolor="#F0F0F0">
    <td height="20" class="bodyText">${ post.id }</td>
    <td height="20" class="bodyText">
        ${ h.link_to_remote(post.name, dict(update="fullview%s" % post.id, url=h.url_for(action='fullview/%s' % post.id)))}
    </td>
    <td height="20" class="bodyText">${ post.author }</td>
    <td height="20" class="bodyText">${ post.year }</td>
    <td height="20" class="bodyText">
        <input type="button" value="Выбрать" onClick="add_biblio('${ post.name }', '${ post.id }');return false;" class="BoxCenter">
    </td>
  </tr>
  <tr id="trShowEdit${ post.id }">
      <td colspan="8" id="td${ post.id }">
          <div id="fullview${ post.id }" />
  </td></tr>
%endfor
</table>
%if c.pages is not None:
    <%include file="toolPanel.myt"/>
%endif
